<?php
class DAO_NewsClass
{
    #船舶
    const SHIPYARD_ID=1;
    //船舶行情
    const SHIPYARD_CONJUNCTURE_ID=11;
    //船厂动态
    const SHIPYARD_TRENDS_ID=12;
    //船厂订单
    const SHIPYARD_ORDERSHEET_ID=13;
    //运行分析
    const SHIPYARD_ANALYSIS_ID=14;



    #船配
    const ANCILLARY_ID=2;
    //船配资讯
    const ANCILLARY_NEWS_ID=21;
    //船配企业动态
    const ANCILLARY_COMPANY_ID=22;
    //船配订单
    const ANCILLARY_ORDERSHEET_ID=23;
    //钢材行情
    const ANCILLARY_STEELS_ID=24;


    
    #航运
    const SHIPPING_ID=3;
    //船运市场
    const SHIPPING_MARKET_ID=31;
    //船东动态
    const SHIPPING_TRENDS_ID=32;

    #海工
    const MARITIMEWORKS_ID=4;
    //海工动态
    const MARITIMEWORKS_TRENDS_ID=41;
    //海工订单
    const MARITIMEWORKS_ORDERSHEET_ID=42;

    #数据
    const DATA_ID=5;
    //新船市场
    const DATA_NEW_ID=51;
    //二手船市场
    const DATA_SECOND_ID=52;
    //航运市场
    const DATA_SCRAP_ID=53;
    //拆船市场
    const DATA_SHIPPING_ID=54;
    //钢材市场
    const DATA_STEELS_ID=55;
    //租船市场
    const DATA_RENT_ID=56;
    

    #融资
    const FINACING_ID=6;
    //信贷政策
    const FINACING_POLICY_ID=61;
    //银企合作
    const FINACING_COOPERATION_ID=62;
    //融资动态
    const FINACING_TRENDS_ID=63;
    //融资上市
    const FINACING_IPO_ID=64;

    #政策法规
    const LAW_ID=7;

    #船型
    const TYPE_ID=8;

    #船配标准
    const STANDARD_ID=9;

    #技术
    const TECHNOLOGY_ID=10;











    #行业展会
    const EXHIBITION_ID=1000;
    //展会新闻
    const EXHIBITION_NEWS_ID=1001;
    //参展回顾
    const EXHIBITION_REVIEW_ID=1002;
    //展会指南
    const EXHIBITION_GUIDE_ID=1003;


    #交易
    const Transaction_ID=2000;
    const Transaction_Share_ID=2001;

    

    #观察
    const OBSERVE_ID=3000;
    //最新评论
    const OBSERVE_COMMENT_ID=3001;
    //读者留言
    const OBSERVE_MESSAGE_ID=3002;
    //访谈观点
    const OBSERVE_INTERVIEW_ID=3003;


    
    #本网动态
    const Trends_ID=4000;

    #新闻专题
    const Topic_ID=5000;


    
    /**
     * 获取类别名称
     */
    public static function GetNameByID($id)
    {
        if(!is_numeric($id)){
            return;
        }

        $data=DB::GetRowByID('news_class','Identifying:'.$id);
        if($data)
            return $data['Name'];
        else
            return NULL;
    }
}
?>